import argparse

def parse_args():
    parser = argparse.ArgumentParser(description='Simple ONNX Runtime Test Tool.')
    parser.add_argument('model_path', help='model path')
    parser.add_argument(
        'num_iters',
        nargs='?',
        type=int,
        default=1000,
        help='model run iterations. default=1000',
    )
    parser.add_argument(
        '--debug',
        action='store_true',
        help='pause execution to allow attaching a debugger.',
    )
    parser.add_argument('--profile'
            , action='store_true'
            , help='enable chrome timeline trace profiling.')
    parser.add_argument(
        '--symbolic_dims',
        default={},
        type=lambda s: dict(x.split('=') for x in s.split(',')),
        help='Comma separated name=value pairs for any symbolic dimensions in the model input. '
        'e.g. --symbolic_dims batch=1,seqlen=5. '
        'If not provided, the value of 1 will be used for all symbolic dimensions.',
    )
    parser.add_argument('-ol'
            , '--ort-log-level'
            , type=int
            , default=3
            , help='设置onnxruntime的日志输出基本')

    return parser.parse_args()
